package com.demo.config;

import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Import;

@Configuration
@ComponentScan({"com.demo.controller", "com.demo.service"})
@Import({JdbcConfig.class, MybatisConfig.class})
public class SpringConfig {
//  1. 声明身份 是Spring核心配置类 @Configuration
//  2. 负责扫描controller.和service包。接管这些类的Bean @ComponentScan({"com.demo.controller","com.demo.service"})
//  3. 还负责整合 JdbcConfig 和MybatisConfig


}
